﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeFile="subject.aspx.cs" Inherits="subject" %>

<asp:Content ID="Content1" ContentPlaceHolderID="titleContent" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="headContent" runat="Server">
    <style type="text/css">
        #index-body {
            padding-left: 10px;
        }
    </style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="mainContent" runat="Server">
    <div id="index-body">

        <form runat="server">
            <div class="row">
                <div class="col-sm-5">
                    <h3 style="margin-left: 20px; margin-top: 5px;">科目</h3>
                </div>
                <div class="col-sm-5">
                    <div class="input-group pull-right" style="width: 250px;">
                        <input type="text" class="form-control" name="keyword" placeholder="输入科目检索." onkeydown="if(event.keyCode == 13) $('.searchbutton').click();" />
                        <span class="input-group-addon" style="cursor: pointer;" id="sizing-addon1" onclick="$('.searchbutton').click();"><i class="cus-icon-search">&nbsp;</i></span>
                    </div>

                </div>
                <div class="col-sm-2">
                    <div class="pull-right btn-group" role="group" aria-label="...">
                        <asp:Button ID="btnSortHot" CommandName="VISITS" runat="server" CssClass="btn btn-default" Text="热度" OnClick="btnSort_Click" UseSubmitBehavior="false"></asp:Button>
                        <asp:Button ID="btnSortTop" CommandName="DATE" runat="server" CssClass="btn btn-default" Text="更新" OnClick="btnSort_Click" UseSubmitBehavior="false"></asp:Button>
                    </div>
                    <div class="pull-right text-right" style="margin-top: 5px; font-size: 16px;">排序:&nbsp;</div>

                </div>
                <span class="hidden">
                    <asp:Button runat="server" name="btnPost" CssClass="searchbutton" UseSubmitBehavior="false" OnClick="btnPost_Click" />
                </span>
            </div>
            <hr />
            <div>
                <asp:Repeater ID="listSubject" runat="server">
                    <ItemTemplate>
                        <div style="float: left; width: 150px; height: 130px; margin: 10px;">
                            <div class="text-center">
                                <img src="<%#Eval("img") %>" alt="<%#Eval("title") %>" />
                            </div>
                            <p class="text-center">
                                <a href="subject-nav.aspx?sid=<%# Eval("sid") %>&gsid=<%# Eval("gsid") %>"><%#Eval("title") %></a>
                            </p>
                        </div>
                    </ItemTemplate>
                </asp:Repeater>
                <div class="clearfix"></div>
            </div>
            <div class="clearfix"></div>
            <br />
            <div>
                <input type="hidden" id="txtGoTo" name="txtGoTo" value="0" />
                <div class="btn-group pull-left" role="group">
                    <button type="button" class="btn btn-default" onclick="$('#txtGoTo').val('1');$('.gotoindex').click();">1</button>
                    <button type="button" class="btn btn-default" onclick="$('#txtGoTo').val('<%=Index-1 %>');$('.gotoindex').click();"><<</button>
                    <button type="button" class="btn btn-default" onclick="$('#txtGoTo').val('<%=Index+1 %>');$('.gotoindex').click();">>></button>
                    <button type="button" class="btn btn-default" onclick="$('#txtGoTo').val('<%=TotalSize %>');$('.gotoindex').click();"><%=TotalSize %></button>
                    <input type="text" class="form-control" style="width: 20px; margin-left: 2px;" placeholder="Go" onkeydown="if(event.keyCode==13) { $('#txtGoTo').val(this.value);$('.gotoindex').click();}" />
                    <asp:Button runat="server" CssClass="hidden gotoindex" UseSubmitBehavior="false" OnClick="btnNavigate_Click" />
                </div>
                <div class="pull-right">
                    <%=Index %>/<%=TotalSize %>页
                </div>
            </div>
        </form>

    </div>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="scriptContent" runat="Server">
</asp:Content>

